import request from '@/utils/request'

/*
* 工序要点
* */
// 查询工序要点列表
export function listCheckConfig(query) {
  return request({
    url: '/gcxt/checkConfig/list',
    method: 'post',
    data: query
  })
}

// 查询工序要点详细
export function getCheckInfo(query) {
  return request({
    url: '/gcxt/checkConfig/get',
    method: 'get',
    params: query
  })
}

// 新增工序要点
export function addCheckConfig(data) {
  return request({
    url: '/gcxt/checkConfig',
    method: 'post',
    data: data
  })
}

// 新增批量工序要点
export function addBatchCheckConfig(data) {
  return request({
    url: '/gcxt/checkConfig/batch',
    method: 'post',
    data: data
  })
}
// 新增批量工序要点
export function addBatchCheckConfigByBuildId(data) {
  return request({
    url: '/gcxt/checkConfig/batchByBuildIds',
    method: 'post',
    data: data
  })
}
// 修改工序要点
export function updateCheckConfig(data) {
  return request({
    url: '/gcxt/checkConfig',
    method: 'put',
    data: data
  })
}

// 删除工序要点
export function delCheckConfig(checkId) {
  return request({
    url: '/gcxt/checkConfig/delete',
    method: 'delete',
    params: { id: checkId }
  })
}
// 批量删除工序要点
export function delCheckConfigBetch(checkIds) {
  return request({
    url: '/gcxt/checkConfig/deleteBatch',
    method: 'delete',
    params: { ids: checkIds }
  })
}
